<!DOCTYPE html>
<html>
<head>
    <title>注册</title>
    <link rel="stylesheet" href="{{ url_for('static', filename='css/auth.css') }}">
</head>
<body>
    <div class="login-container">
        <h2>注册</h2>
        {% if error %}
        <div class="error-message">{{ error }}</div>
        {% endif %}
        <form method="POST" action="{{ url_for('register') }}">
            <div class="form-group">
                <label for="username">用户名:</label>
                <input type="text" id="username" name="username" required>
            </div>
            <div class="form-group">
                <label for="password">密码:</label>
                <input type="password" id="password" name="password" required>
            </div>

            <button type="submit">注册</button>
        </form>
        <p>已有账号? <a href="{{ url_for('login') }}">登录</a></p>
    </div>
</body>
</html>